package fr.perso.spring.jmx;

import org.springframework.jmx.export.annotation.ManagedAttribute;
import org.springframework.jmx.export.annotation.ManagedOperation;
import org.springframework.jmx.export.annotation.ManagedOperationParameter;
import org.springframework.jmx.export.annotation.ManagedOperationParameters;

public interface IJmxTestBean {

	@ManagedAttribute(description = "The Age Attribute", currencyTimeLimit = 15)
	public int getAge();

	public void setAge(int age);

	@ManagedAttribute(description = "The Name Attribute", currencyTimeLimit = 20, defaultValue = "bar", persistPolicy = "OnUpdate")
	public void setName(String name);

	@ManagedAttribute(defaultValue = "foo", persistPeriod = 300)
	public String getName();

	@ManagedOperation(description = "Add two numbers")
	@ManagedOperationParameters({ @ManagedOperationParameter(name = "x", description = "The first number"),
			@ManagedOperationParameter(name = "y", description = "The second number") })
	public int add(int x, int y);

	public void dontExposeMe();

}